<!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:py="http://genshi.edgewall.org/"
      xmlns:xi="http://www.w3.org/2001/XInclude" py:strip="">
  <py:match path="div[@id='content']" once="true"><div py:attrs="select('@*')">
    ${select('*|text()')}
    <form py:if="'WIKI_DELETE' in perm(page.resource) and
                 (not changes[0].diffs or new_version == latest_version)"
      method="get" action="${href.wiki(page.name)}">
      <div>
        <input type="hidden" name="action" value="delete" />
        <input type="hidden" name="version" value="$new_version" />
        <input type="hidden" name="old_version" value="$old_version" />
        <py:choose>
          <input py:when="new_version - old_version &gt; 1" type="submit" name="delete_version" value="${_('Delete version %(old_version)d to version %(version)d', old_version=(old_version + 1), version=new_version)}" />
          <input py:otherwise="" type="submit" name="delete_version" value="${_('Delete version %(version)d', version=new_version)}" />
        </py:choose>
      </div>
    </form>
  </div></py:match>
  <py:with vars="resource = page.resource">
    <xi:include href="diff_view.html" />
  </py:with>
</html>
